#pragma once
#include <Rz/IObject.h>
#include <Rz/Graphics/Render/IDeviceResource.h>
#include <Rz/Graphics/Scene/Node.h>

RZ_CLASS_FWD_DECL3(Rz, Graphics, Render, Viewport);
RZ_CLASS_FWD_DECL3(Rz, Graphics, Scene, CameraNode);

namespace Rz { namespace Graphics { namespace Render { namespace CompositionAdapters {

class ICompositionAdapter :
	virtual public IObject,
	virtual public IDeviceResource
{
	public:
		RZ_RTTI_INTERFACE(Rz::Graphics::Render::CompositionAdapters, ICompositionAdapter);
		RZ_RTTI_IMPLEMENTS(IObject, IDeviceResource);
		RZ_RTTI_END;

		RZ_INLINE virtual const Scene::CameraNode* GetCamera() const { return _camera; }
		RZ_INLINE virtual Scene::CameraNode* GetCamera() { return _camera; }
		RZ_INLINE virtual void SetCamera(Scene::CameraNode* camera) { _camera = camera; }

		RZ_INLINE virtual const Viewport* GetViewport() const { return _viewport; }
		RZ_INLINE virtual Viewport* GetViewport() { return _viewport; }
		RZ_INLINE virtual void SetViewport(Viewport* viewport) { _viewport = viewport; }

		virtual void Draw(Scene::Node::Collection& scene) = 0;

	private:
		Ptr<Scene::CameraNode> _camera;
		Ptr<Viewport> _viewport;

};

} } } }
